<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

include './application/beans/TestArrayBean.php';

class BeanTest extends CI_Controller {

	public function index()
	{
		// create class
		$cls1 = new TestArrayBean();
		$cls1->setData('beanTitle','beanName','beanDate');

		$result['result1'] = $cls1;

		// create class array
		for ($i=0;$i<10;$i++) {
			$cls2 = new TestArrayBean();
			$cls2->setData('beanTitle' . $i,'beanName' . $i,'beanDate' . $i);
			$data[$i] = $cls2;
		}

		$result['result2'] = $data;

		$this->load->view('BeanTest_view', $result);
	}
}

/* End of file welcome.php */
/* Location: ./application/controllers/welcome.php */